 <!DOCTYPE html>
<html>

<head>

    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    

    <title>{$Think.config.site.title} - 配送列表</title>

    <meta name="keywords" content="{$Think.config.site.keywords}">

    <link href="{$Think.config.site.resource_url}css/bootstrap.min.css?v=3.3.5" rel="stylesheet">
    <link href="{$Think.config.site.resource_url}css/font-awesome.min.css?v=4.4.0" rel="stylesheet">
    <link href="{$Think.config.site.resource_url}css/plugins/iCheck/custom.css" rel="stylesheet">
    <link href="{$Think.config.site.resource_url}css/animate.min.css" rel="stylesheet">
    <link href="{$Think.config.site.resource_url}css/style.min.css?v=4.0.0" rel="stylesheet">

</head>
<style>
#listtable .fa{
	cursor:pointer;
	color:#1ab394;
	margin-right:1em;
}
th .tag{font-size: 12px; color: #e66c6c; font-weight: normal;}
.ibox-title .tag{font-size: 12px; color: #e66c6c; font-weight: normal; display: inline-block; margin-left: 20px;}
.specval-hide{display: none;}
</style>
<body class="gray-bg">
    <div class="container-fluid">
      <div class="row">
          <div class="col-xs-12">
                <div class="ibox float-e-margins">
                    <div class="ibox-title">
                        <h5>订单商品列表</h5>
                    </div>
                    <div class="ibox-content">
                        <div class="row">
                          	<!-- <div class="col-xs-12">
                                <div class="input-group pull-right">
                                <form action="{:url('details')}" method="get" enctype="application/x-www-form-urlencoded">
                                <div class="input-group">
								<input type="hidden" name="purchase_id" value="{$purchase_id}"/>
                                    <input type="text" placeholder="请输入关键词" class="input-sm form-control" value="{$Think.get.keywords ?? ''}" name="keywords">
                                    <span class="input-group-btn">
									<button type="submit" class="btn btn-sm btn-primary"> 搜索</button> </span>
                                </div>
                                </form>
                                </div>
                            </div> -->
                        </div>
						<table class="table table-striped" id="listtable">
							<thead>
								<tr>
									<!-- <th>商品图片</th> -->
									<th>商品名称</th>
									<th>数量</th>
									<th style='text-align: center;'>操作</th>
								</tr>
							</thead>
							<tbody>
								{volist name="list" id="vo"}
								<tr data-pg_id="{$vo.pg_id}">
									<!-- <td><img src="{$vo.picture}" style="max-height: 60px; max-width: 60px"></td> -->
									<td class="goodsname">{$vo.goods_name}&nbsp;&nbsp;[&nbsp;1*{$vo.goods_spec_name}&nbsp;({$vo.goods_specval_name})&nbsp;]</td>
									<td>{$vo['num']}</td>
									<td><a data-order_goods_id="{$vo.order_goods_id}" class="fa fa-edit refund" style="width:43px;margin-right:0px;"> 退货</a></td>
								</tr>
							   {/volist}
							</tbody>
						</table>
						<button type="button" class="btn btn-primary btn-sm" onclick="window.history.back()"><i class="fa fa-backward"></i> 返回</button>
                    </div>
                </div>
            </div>
        </div>
    </div>

    <script src="{$Think.config.site.resource_url}js/jquery.min.js?v=2.1.4"></script>
    <script src="{$Think.config.site.resource_url}js/bootstrap.min.js?v=3.3.5"></script>
    <script src="{$Think.config.site.resource_url}js/plugins/peity/jquery.peity.min.js"></script>
    <script src="{$Think.config.site.resource_url}js/plugins/iCheck/icheck.min.js"></script>
    <script src="{$Think.config.site.resource_url}js/plugins/layer/layer.js"></script>
    <script src="{$Think.config.site.common_resource_url}js/majax.js"></script>
    <script src="{$Think.config.site.common_resource_url}js/jedit.js"></script>
<!-- 	<script>
		$(document).on('blur','.real_num',function(){
			var pg_id = $(this).closest('tr').data('pg_id');
			var real_num = $(this).val();
			if(real_num == '' || real_num == null){
				return false;
			}else{
				$.post('{:url("update")}',{pg_id: pg_id,real_num: real_num},function(msg){
					if(msg.code = 1){
						layer.msg(msg.msg,{icon: 1});
					}else{
						layer.msg(msg.msg,{icon: 5});
					}
				});
			}
		});
		
		$(document).on('blur','.cur_price',function(){
			var pg_id = $(this).closest('tr').data('pg_id');
			var cur_price = $(this).val();
			if(cur_price == '' || cur_price == null){
				return false;
			}else{
				$.post('{:url("update")}',{pg_id: pg_id,cur_price: cur_price},function(msg){
					if(msg.code = 1){
						layer.msg(msg.msg,{icon: 1});
					}else{
						layer.msg(msg.msg,{icon: 5});
					}
				});
			}
		});
	</script> -->
</body>
</html>
<script type="text/javascript">
var layer_font='';
$(document).on('click','.refund',function(){
	var order_goods_id = $(this).data('order_goods_id');
	layer_font=layer.open({
		type: 2,
		title: '退货',
		shadeClose: true,
		shade: 0.8,
		area: ['100%', '60%'],
		content: '{:url("refund")}?order_goods_id=' + order_goods_id //iframe的url
	}); 
});
function editSuccess(d){
    layer.close(layer_font);
    layer.msg(d.msg, {icon: 1},function(){
        location.reload(true);
    });
}
</script>